/*
 * Copyright (C) 2016 The Fosafer Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.fosafer.idcard_demo.app;

import android.app.Application;

import com.fosafer.idcard_demo.util.AppManagerUtil;

/**
 * Package:      [com.fosafer.idcard_demo.app]
 * ClassName:    [IDCardApp]
 * Description:  [存放app中一些配置信息]
 * Author:       [cuijianzhi]
 * CreateDate:   [2016/04/12 15:22]
 * UpdateUser:   [cuijianzhi]
 * UpdateDate:   [2016/04/12 15:22]
 * UpdateRemark: [Update Description]
 * Version:      [v1.0.0]
 * <p>
 * Copyright (c) 2016 Fosafer Co.,Ltd. All rights reserved.
 */
public final class IDCardApp extends Application {
    /**
     * Application对象.
     */
    private static IDCardApp instance;

    public IDCardApp() {
    }


    public static IDCardApp getInstance() {
        return instance;
    }


    @Override
    public void onCreate() {
        super.onCreate();
        instance = this;

    }


    @Override
    public void onLowMemory() {
        super.onLowMemory();
        AppManagerUtil.getInstance().appExit();
    }


}
